﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Warehouse.DataAccess
{
    public partial class Department : CustomeEntity<Department>
    {
        protected override System.Linq.Expressions.Expression<Func<Department, bool>> GetPredicate()
        {
            return p => p.ID == this.ID;
        }

        #region Public Static Methods

        public static Department GetDepartment(int ID)
        {
            return GetOne(p => p.ID == ID);
        }

        public static Department[] GetDepartments()
        {
            return GetList().ToArray();
        }
        #endregion
    }
}
